# Contributor: Luca Weiss <luca@lucaweiss.eu>

# The group tag is just to easily find this APKBUILD by some scripts for automation
# group=kde-applications
maintainer="team/kde <bribbers@disroot.org>"
pkgname=audiotube
pkgver=24.08.2
pkgrel=0
pkgdesc="Client for YouTube Music"
url="https://invent.kde.org/plasma-mobile/audiotube"
# armhf blocked by qt6-qtdeclarative -> kirigami
arch="all !armhf"
license="GPL-2.0-or-later"
depends="
	gst-plugins-bad
	gst-plugins-good
	kirigami-addons
	kirigami
	purpose
	py3-ytmusicapi
	qt6-qtbase-sqlite
	yt-dlp
	"
makedepends="
	extra-cmake-modules
	futuresql-dev
	kcrash-dev
	ki18n-dev
	kirigami-addons-dev
	kirigami-dev
	py3-pybind11-dev
	python3-dev
	qcoro-dev
	qt6-qtbase-dev
	qt6-qtdeclarative-dev
	qt6-qtmultimedia-dev
	qt6-qtsvg-dev
	samurai
	"
subpackages="$pkgname-lang"
_repo_url="https://invent.kde.org/multimedia/audiotube.git"
source="https://download.kde.org/stable/release-service/$pkgver/src/audiotube-$pkgver.tar.xz"
options="!check" # No tests

build() {
	cmake -B build -G Ninja \
		-DBUILD_WITH_QT6=ON \
		-DCMAKE_BUILD_TYPE=MinSizeRel \
		-DCMAKE_INSTALL_PREFIX=/usr \
		-DCMAKE_INSTALL_LIBDIR=lib
	cmake --build build
}

package() {
	DESTDIR="$pkgdir" cmake --install build
}

sha512sums="
4a3d43ad51d26499f9a0f8f53599a95f1dd25b5042a155b6f8aed955ff337929b78c8e1f054d11a70645cf076059b2f079aa7d3adea8e66118139e2493903092  audiotube-24.08.2.tar.xz
"
